package com.ljq.cksp.pojo;

import org.apache.solr.client.solrj.beans.Field;
import org.springframework.data.annotation.Id;
import org.springframework.data.solr.core.mapping.Indexed;
import org.springframework.data.solr.core.mapping.SolrDocument;

import java.io.Serializable;
import java.util.List;

/**
 * @Author:ljq
 * @Date:2020/3/3
 */
@SolrDocument(solrCoreName = "document")
public class Document implements Serializable {
    @Id
    @Field
    @Indexed
    private String fact;
    @Field
    @Indexed
    private List<Integer> relevantArticles;
    @Field
    @Indexed
    private List<String> accusation;
    @Field
    @Indexed
    private List<String> criminals;
    @Field
    private boolean deathPenalty;
    @Field
    private int imprisonment;
    @Field
    private boolean lifeImprisonment;

    public String getFact() {
        return fact;
    }

    public void setFact(String fact) {
        this.fact = fact;
    }

    public List<Integer> getRelevantArticles() {
        return relevantArticles;
    }

    public void setRelevantArticles(List<Integer> relevantArticles) {
        this.relevantArticles = relevantArticles;
    }

    public List<String> getAccusation() {
        return accusation;
    }

    public void setAccusation(List<String> accusation) {
        this.accusation = accusation;
    }

    public List<String> getCriminals() {
        return criminals;
    }

    public void setCriminals(List<String> criminals) {
        this.criminals = criminals;
    }

    public boolean isDeathPenalty() {
        return deathPenalty;
    }

    public void setDeathPenalty(boolean deathPenalty) {
        this.deathPenalty = deathPenalty;
    }

    public int getImprisonment() {
        return imprisonment;
    }

    public void setImprisonment(int imprisonment) {
        this.imprisonment = imprisonment;
    }

    public boolean isLifeImprisonment() {
        return lifeImprisonment;
    }

    public void setLifeImprisonment(boolean lifeImprisonment) {
        this.lifeImprisonment = lifeImprisonment;
    }

    @Override
    public String toString() {
        return "Document{" +
                "fact='" + fact + '\'' +
                ", relevantArticles=" + relevantArticles +
                ", accusation=" + accusation +
                ", criminals=" + criminals +
                ", deathPenalty=" + deathPenalty +
                ", imprisonment=" + imprisonment +
                ", lifeImprisonment=" + lifeImprisonment +
                '}';
    }
}
